﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace QLHXNK
{
    public partial class FrmBaoCaoChiPhi : Form
    {
        public FrmBaoCaoChiPhi()
        {
            InitializeComponent();
        }

        #region Hàm hỗ trợ
        private void doPrintReport()
        {
            SaveFileDialog dlg = new SaveFileDialog();
            DateTime fromDate = dtpickerTuNgay.Value;
            DateTime toDate = dtpickerDenNgay.Value;

            dlg.FileName = "Bao cao nhap chi phi tu" + fromDate.Day.ToString() + "-" + fromDate.Month.ToString() + "-" + fromDate.Year.ToString() + " den " + toDate.Day.ToString() + "-" + toDate.Month.ToString() + "-" + toDate.Year.ToString() + ".xls";
            if (dlg.ShowDialog() == DialogResult.OK)
            {
                String filePath = dlg.FileName;
                MessageBox.Show(filePath + "\nChưa xong phần này");
                //DataTable table = new DataTable();
            }
        }
        #endregion

        private void btnBaoCao_Click(object sender, EventArgs e)
        {
            doPrintReport();
        }
    }
}